Search
CommonUtils.filter(T, D) Method (Iterator(T), Class(D))
See Also
 






Creates Iterator that iterates only over the subset of the given Iterator that consist of elements of desired type.

Namespace: com.mindfusion.common
Package: com.mindfusion.common

 Syntax

Java  Copy Code

public static <T, D> Iterator<D> filter (
    Iterator<T> unfiltered,
    Class<D> desiredType
)

 Parameters

unfiltered

the collection of items that can be of different type.

desiredType

the class of the items in the collection to be returned.

 Return Value

An iterator over the collection items of the desired type.

 See Also